struct "H3_RESOURCES"
begin
	uint32 木材
	uint32 水银
	uint32 矿石
	uint32 硫磺
	uint32 水晶
	uint32 宝石
	uint32 金币
	goto 0x30
	char[9] 名字
	goto 360
end

enum(int32) HERO_ARTIFACT_CODE
begin
 "无"=-1
 "魔法书"=0x00   "卷轴"=0x01   "神器"=0x02   "投石车"=0x03   "弩车"=0x04   "补给车"=0x05   "急救帐篷"=0x06   "人马战斧"=0x07 
 "黑魔剑"=0x08   "狼人连枷"=0x09   "恶魔之棒"=0x0a   "火神剑"=0x0b   "泰坦之剑"=0x0c   "矮人王盾"=0x0d   "亡灵盾"=0x0e   "狼人王盾"=0x0f 
 "狂魔盾"=0x10   "邪盾"=0x11   "守护神之盾"=0x12   "神兽之冠"=0x13   "骷髅冠"=0x14   "混沌之冠"=0x15   "智慧之冠"=0x16   "地狱王冠"=0x17 
 "雷神之盔"=0x18   "藤木甲"=0x19   "骨质胸甲"=0x1a   "大蛇神胸甲"=0x1b   "巨人战甲"=0x1c   "黄金甲"=0x1d   "泰坦战甲"=0x1e   "神奇战甲"=0x1f 
 "圣靴"=0x20   "天使项链"=0x21   "狮王盾"=0x22   "先知剑"=0x23   "神谕之冠"=0x24   "龙眼戒"=0x25   "赤龙剑"=0x26   "龙盾"=0x27 
 "龙甲"=0x28   "龙骨胫甲"=0x29   "龙翼袍"=0x2a   "龙牙项链"=0x2b   "龙牙冠"=0x2c   "龙眼指环"=0x2d   "幸运三叶草"=0x2e   "预言卡"=0x2f 
 "幸运鸟"=0x30   "勇气胸章"=0x31   "勇士胸章"=0x32   "勇士令"=0x33   "窥镜"=0x34   "望远镜"=0x35   "亡灵护身符"=0x36   "吸血鬼披风"=0x37 
 "死神靴"=0x38   "抗魔链"=0x39   "抗魔披风"=0x3a   "抗魔靴"=0x3b   "树精灵之弓"=0x3c   "神兽之鬃"=0x3d   "天羽箭"=0x3e   "神目鸟"=0x3f 
 "火眼人"=0x40   "真理徽章"=0x41   "政治家勋章"=0x42   "礼仪之戒"=0x43   "天使勋带"=0x44   "旅行者之戒"=0x45   "骑士手套"=0x46   "海神项链"=0x47 
 "炽天之翼"=0x48   "魔力护符"=0x49   "魔法护符"=0x4a   "魔力球"=0x4b   "魔力项圈"=0x4c   "魔戒"=0x4d   "魔法披风"=0x4e   "气灵球"=0x4f 
 "土灵球"=0x50   "火灵球"=0x51   "水灵球"=0x52   "禁魔披风"=0x53   "禁锢之灵"=0x54   "恶运沙漏"=0x55   "火系魔法书"=0x56   "气系魔法书"=0x57 
 "水系魔法书"=0x58   "土系魔法书"=0x59   "水神靴"=0x5a   "黄金弓"=0x5b   "永恒之球"=0x5c   "毁灭之球"=0x5d   "活力之戒"=0x5e   "生命之戒"=0x5f 
 "活力圣瓶"=0x60   "极速项链"=0x61   "神行靴"=0x62   "极速披风"=0x63   "冷静挂件"=0x64   "光明挂件"=0x65   "神圣挂件"=0x66   "生命挂件"=0x67 
 "死神挂件"=0x68   "自由挂件"=0x69   "电神挂件"=0x6a   "清醒挂件"=0x6b   "勇气挂件"=0x6c   "水晶披风"=0x6d   "宝石戒指"=0x6e   "水银瓶"=0x6f 
 "矿石车"=0x70   "硫磺指环"=0x71   "木材车"=0x72   "黄金囊"=0x73   "黄金袋"=0x74   "黄金包"=0x75   "天赐神足"=0x76   "天赐神胯"=0x77 
 "天赐神躯"=0x78   "天赐神臂"=0x79   "天赐神首"=0x7a   "航海家之帽"=0x7b   "魔法师之帽"=0x7c   "战争枷锁"=0x7d   "禁魔球"=0x7e   "龙之血瓶"=0x7f 
 "末日之刃"=0x80   "天使联盟"=0x81   "鬼王斗篷"=0x82   "神圣血瓶"=0x83   "诅咒铠甲"=0x84   "天赐神兵"=0x85   "龙王神力"=0x86   "泰坦之箭"=0x87 
 "海洋之帽"=0x88 "幻影神弓"=0x89 "魔力源泉"=0x8a "法师之戒"=0x8b "丰收号角"=0x8c "外交套装"=0x8d "Mired in Neutrality"=0x8e "Ironfist of the Ogre"=0x8f
end

enum(uint8) HERO_SKILL_LEVEL
begin
	"无"=0
	"初级"=1
	"中级"=2
	"高级"=3
end

enum(uint8) DIRECTION
begin
	"北"=0
	"东北"=1
	"东"=2
	"东南"=3
	"男"=4
	"西南"=5
	"西"=6
	"西北"=7
end

enum CREATURE_TYPE
begin
	"无"=-1
	"枪兵"=0x00
	"戟兵"=0x01
	"弓箭兵"=0x02
	"神射手"=0x03
	"狮鹫"=0x04
	"皇家狮鹫"=0x05
	"剑士"=0x06
	"十字军"=0x07
	"僧侣"=0x08
	"祭司"=0x09
	"骑兵"=0x0a
	"骑士"=0x0b
	"天使"=0x0c
	"大天使"=0x0d
	"半人马"=0x0e
	"半人马首领"=0x0f
	"矮人"=0x10
	"战斗矮人"=0x11
	"木精灵"=0x12
	"大精灵"=0x13
	"飞马"=0x14
	"银飞马"=0x15
	"枯木卫士"=0x16
	"枯木战士"=0x17
	"独角兽"=0x18
	"独角神兽"=0x19
	"绿龙"=0x1a
	"金龙"=0x1b
	"小妖精"=0x1c
	"大妖精"=0x1d
	"石像鬼"=0x1e
	"石像怪"=0x1f
	"石人"=0x20
	"铁人"=0x21
	"法师"=0x22
	"大法师"=0x23
	"神怪"=0x24
	"神怪主"=0x25
	"蛇女"=0x26
	"蛇妖"=0x27
	"巨人"=0x28
	"泰坦巨人"=0x29
	"小怪物"=0x2a
	"怪物"=0x2b
	"歌革"=0x2c
	"玛各"=0x2d
	"地狱猎犬"=0x2e
	"三首猎犬"=0x2f
	"恶鬼"=0x30
	"长角恶鬼"=0x31
	"邪神"=0x32
	"邪神王"=0x33
	"火精灵"=0x34
	"烈火精灵"=0x35
	"恶魔"=0x36
	"大恶魔"=0x37
	"骷髅兵"=0x38
	"骷髅勇士"=0x39
	"行尸"=0x3a
	"僵尸"=0x3b
	"幽灵"=0x3c
	"阴魂"=0x3d
	"吸血鬼"=0x3e
	"吸血鬼王"=0x3f
	"尸巫"=0x40
	"尸巫王"=0x41
	"暗黑骑士"=0x42
	"恐怖骑士"=0x43
	"骨龙"=0x44
	"鬼龙"=0x45
	"洞穴人"=0x46
	"地狱洞穴人"=0x47
	"鹰身女妖"=0x48
	"鹰身女巫"=0x49
	"斜眼"=0x4a
	"毒眼"=0x4b
	"美杜莎"=0x4c
	"美杜莎女王"=0x4d
	"牛头怪"=0x4e
	"牛头王"=0x4f
	"蝎狮"=0x50
	"毒蝎狮"=0x51
	"赤龙"=0x52
	"黑龙"=0x53
	"大耳怪"=0x54
	"大耳怪王"=0x55
	"恶狼骑士"=0x56
	"恶狼斗士"=0x57
	"半兽人"=0x58
	"半兽人首领"=0x59
	"食人魔"=0x5a
	"食人魔王"=0x5b
	"大雕"=0x5c
	"雷鸟"=0x5d
	"独眼巨人"=0x5e
	"独眼王"=0x5f
	"比蒙"=0x60
	"比蒙巨兽"=0x61
	"狼人"=0x62
	"大狼人"=0x63
	"蜥蜴人"=0x64
	"蜥蜴勇士"=0x65
	"毒蝇"=0x66
	"龙蝇"=0x67
	"蜥蜴"=0x68
	"巨蜥"=0x69
	"野牛"=0x6a
	"蛮牛"=0x6b
	"飞龙"=0x6c
	"飞龙王"=0x6d
	"九头怪"=0x6e
	"终极九头怪"=0x6f
	"劳工/气元素"=0x70
	"机械魔女/土元素"=0x71
	"技师/火元素"=0x72
	"生化人/水元素"=0x73
	"金人"=0x74
	"钻石人"=0x75
	"新兵/小精灵"=0x76
	"兵长/精灵"=0x77
	"魔法元素/精神元素"=0x78
	"核电子人/魔法元素"=0x79
	"暴风元素"=0x7a
	"改造人/冰元素"=0x7b
	"冰元素"=0x7c
	"异变魔女/石元素"=0x7d
	"能量元素"=0x7e
	"监工/雷元素"=0x7f
	"岩浆元素"=0x80
	"工程师/烈火元素"=0x81
	"无畏战士/火鸟"=0x82
	"凤凰"=0x83
	"圣龙"=0x84
	"水晶龙"=0x85
	"紫龙"=0x86
	"毒龙"=0x87
	"魔幻法师"=0x88
	"幻影射手"=0x89
	"投石矮人"=0x8a
	"妖精/农民"=0x8b
	"磁电子人/野猪"=0x8c
	"不朽卫士/木乃伊"=0x8d
	"游牧民"=0x8e
	"盗贼"=0x8f
	"索尔巨人"=0x90
end

struct "HERO_MAGIC"
begin
	bool "召船术" //0x00
	bool "摧毁船只" //0x01
	bool "透视之眼" //0x02
	bool "透视大地" //0x03
	bool "伪装大法" //0x04
	bool "透视大气" //0x05
	bool "飞行奇术" //0x06
	bool "凌波微步" //0x07
	bool "异次元之门" //0x08
	bool "时空之门" //0x09
	bool "流沙陷阱" //0x0a
	bool "埋设地雷" //0x0b
	bool "大力神盾" //0x0c
	bool "烈火魔墙" //0x0d
	bool "地动山摇" //0x0e
	bool "魔法神箭" //0x0f
	bool "霹雳寒冰" //0x10
	bool "霹雳闪电" //0x11
	bool "雷鸣炮弹" //0x12
	bool "连锁闪电" //0x13
	bool "寒冰魔环" //0x14
	bool "连珠火球" //0x15
	bool "地狱烈焰" //0x16
	bool "流星火雨" //0x17
	bool "死亡波纹" //0x18
	bool "亡灵杀手" //0x19
	bool "末日审判" //0x1a
	bool "护体神盾" //0x1b
	bool "大气神盾" //0x1c
	bool "烈火神盾" //0x1d
	bool "御气奇术" //0x1e
	bool "御火奇术" //0x1f
	bool "御水奇术" //0x20
	bool "御土奇术" //0x21
	bool "抗魔大法" //0x22
	bool "驱魔大法" //0x23
	bool "魔法神镜" //0x24
	bool "疗伤" //0x25
	bool "转世重生" //0x26
	bool "聚灵奇术" //0x27
	bool "牺牲" //0x28
	bool "圣灵佑佐" //0x29
	bool "恶咒附身" //0x2a
	bool "嗜血奇术" //0x2b
	bool "百发百中" //0x2c
	bool "虚弱无力" //0x2d
	bool "护体石肤" //0x2e
	bool "毁灭之光" //0x2f
	bool "祈祷" //0x30
	bool "欢欣鼓舞" //0x31
	bool "悲痛欲绝" //0x32
	bool "幸运之神" //0x33
	bool "大难临头" //0x34
	bool "攻击加速" //0x35
	bool "迟缓大法" //0x36
	bool "屠戮成性" //0x37
	bool "孤注一掷" //0x38
	bool "泰坦之箭" //0x39
	bool "反戈一击" //0x3a
	bool "丧心病狂" //0x3b
	bool "蛊惑人心" //0x3c
	bool "失忆大法" //0x3d
	bool "双目失明" //0x3e
	bool "瞬间移动" //0x3f
	bool "驱除障碍" //0x40
	bool "镜像大法" //0x41
	bool "召唤火元素" //0x42
	bool "召唤土元素" //0x43
	bool "召唤水元素" //0x44
	bool "召唤气元素" //0x45
	goto 70
end

struct "HERO_SKILL"
begin
	uint8 寻路术
	uint8 箭术
	uint8 后勤学
	uint8 侦察术
	uint8 外交术
	uint8 航海术
	uint8 领导术
	uint8 智慧术
	uint8 神秘术
	uint8 幸运术
	uint8 弹道术
	uint8 鹰眼术
	uint8 招魂术
	uint8 理财术
	uint8 火系魔法
	uint8 气系魔法
	uint8 水系魔法
	uint8 土系魔法
	uint8 学术
	uint8 战术
	uint8 炮术
	uint8 学习能力
	uint8 进攻术
	uint8 防御术
	uint8 智力
	uint8 魔力
	uint8 抵抗力
	uint8 急救术
end

struct "HERO_SKILL_LEVEL_LIST"
begin
	HERO_SKILL_LEVEL 寻路术
	HERO_SKILL_LEVEL 箭术
	HERO_SKILL_LEVEL 后勤学
	HERO_SKILL_LEVEL 侦察术
	HERO_SKILL_LEVEL 外交术
	HERO_SKILL_LEVEL 航海术
	HERO_SKILL_LEVEL 领导术
	HERO_SKILL_LEVEL 智慧术
	HERO_SKILL_LEVEL 神秘术
	HERO_SKILL_LEVEL 幸运术
	HERO_SKILL_LEVEL 弹道术
	HERO_SKILL_LEVEL 鹰眼术
	HERO_SKILL_LEVEL 招魂术
	HERO_SKILL_LEVEL 理财术
	HERO_SKILL_LEVEL 火系魔法
	HERO_SKILL_LEVEL 气系魔法
	HERO_SKILL_LEVEL 水系魔法
	HERO_SKILL_LEVEL 土系魔法
	HERO_SKILL_LEVEL 学术
	HERO_SKILL_LEVEL 战术
	HERO_SKILL_LEVEL 炮术
	HERO_SKILL_LEVEL 学习能力
	HERO_SKILL_LEVEL 进攻术
	HERO_SKILL_LEVEL 防御术
	HERO_SKILL_LEVEL 智力
	HERO_SKILL_LEVEL 魔力
	HERO_SKILL_LEVEL 抵抗力
	HERO_SKILL_LEVEL 急救术
end

struct "HERO_ARTIFACT"
begin
    HERO_ARTIFACT_CODE code
    int32 attr
end

struct "HERO_BODY_ARTIFACTS"
begin
	HERO_ARTIFACT 头 // 1
	HERO_ARTIFACT 肩 // 2
	HERO_ARTIFACT 颈 // 3
	HERO_ARTIFACT 右手 // 4
	HERO_ARTIFACT 左手 // 5
	HERO_ARTIFACT 胸 // 6
	HERO_ARTIFACT 右手指 // 7
	HERO_ARTIFACT 左手指 // 8
	HERO_ARTIFACT 脚 // 9
	HERO_ARTIFACT 杂物1 // 10
	HERO_ARTIFACT 杂物2 // 11
	HERO_ARTIFACT 杂物3 // 12
	HERO_ARTIFACT 杂物4 // 13
	HERO_ARTIFACT 战争机器1 // 14
	HERO_ARTIFACT 战争机器2 // 15
	HERO_ARTIFACT 战争机器3 // 16
	HERO_ARTIFACT 战争机器4 // 17
	HERO_ARTIFACT 魔法书 // 18
	HERO_ARTIFACT 杂物5 // 19
end

struct "HERO_BAG_ARTIFACTS"
begin
	HERO_ARTIFACT[64] 宝物
end

struct "HERO_BASIC"
begin
	uint16 x
	uint16 y
	uint16 z
	skip 18
	uint16 剩余魔法点
	uint8 特长
	skip 7
	uint8 颜色
	char[13] 名字
	uint32 类型
	uint8 模板
	skip 18
	DIRECTION 方向
	skip 1
	uint32 总移动力
	uint32 剩余移动力
	int32 经验值
	int16 级别
goto 1142
	section 四围
		uint8 进攻力
		uint8 防守力
		uint8 力量
		uint8 知识
	endsection
end

struct "HERO"
// wangdm001@163.com
begin
	HERO_BASIC basic
goto 0x91
	// ------------------
	section units
		CREATURE_TYPE[7] 类别
		int32[7] 数量
	endsection

	section Skills
		HERO_SKILL_LEVEL_LIST levels
		HERO_SKILL sequence
		uint8 count
	endsection

goto 0x12d
	HERO_BODY_ARTIFACTS 随身宝物
	uint8[15] flags
	HERO_BAG_ARTIFACTS 背囊
	uint32 nBag
goto 0x3ea
	HERO_MAGIC magic_1
	HERO_MAGIC magic_2
goto 1170
end
